package org.linlinjava.litemall.admin.web2.user.resp;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.linlinjava.litemall.core.util.DateTimeUtil;
import org.linlinjava.litemall.core.util.Util;
import org.linlinjava.litemall.db.domain.TWxCashoutApply;

import java.math.BigDecimal;
import java.time.LocalDateTime;

@ApiModel
public class UResp7 {

    @ApiModelProperty("id")
    private Integer id;
    @ApiModelProperty("时间")
    private String createdTime;
    @ApiModelProperty("单号")
    private String transNo;
    @ApiModelProperty("姓名")
    private String name;
    @ApiModelProperty("用户角色")
    private String userRoleName;
    @ApiModelProperty("微信号")
    private String wx;
    @ApiModelProperty("手机号")
    private String phone;
    @ApiModelProperty("金额")
    private Double amount;
    private Integer status;
    @ApiModelProperty("状态")
    private String statusStr;

    @ApiModelProperty("描述[该字段不在列表展示出来]")
    private String description;

    @ApiModelProperty("微信转账交易号[该字段不在列表展示出来]")
    private String payNo;


    public UResp7(TWxCashoutApply entity) {
        Util.copy(entity, this);
        createdTime = entity.getCreatedTime().format(DateTimeUtil.format);
        amount = entity.getAmount().doubleValue();
        switch (status) {
            case 0:
                statusStr = "未审核";
                break;
            case 1:
                statusStr = "已审核";
                break;
            case 2:
                statusStr = "审核失败";
                break;
        }
    }

    public UResp7() {
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getPayNo() {
        return payNo;
    }

    public void setPayNo(String payNo) {
        this.payNo = payNo;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(String createdTime) {
        this.createdTime = createdTime;
    }

    public String getTransNo() {
        return transNo;
    }

    public void setTransNo(String transNo) {
        this.transNo = transNo;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getUserRoleName() {
        return userRoleName;
    }

    public void setUserRoleName(String userRoleName) {
        this.userRoleName = userRoleName;
    }


    public String getWx() {
        return wx;
    }

    public void setWx(String wx) {
        this.wx = wx;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Double getAmount() {
        return amount;
    }

    public void setAmount(Double amount) {
        this.amount = amount;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getStatusStr() {
        return statusStr;
    }

    public void setStatusStr(String statusStr) {
        this.statusStr = statusStr;
    }
}
